home *** CD-ROM | disk | FTP | other *** search
- Short: V1.0 Create rename/un scripts num-orderd +src
- Author: mark@kontumnam.freeserve.co.uk (Mark Weller)
- Uploader: mark@kontumnam.freeserve.co.uk (Mark Weller)
- Type: util/cli
- Url: www.kontumnam.freeserve.co.uk
-
- Arename
- --------
- This program produces a script file to rename chosen files in a chosen
- directory in a numberd format with a few other options.
-
- * The scripts use the amigados rename command
- * you can rename all files in directory or by files by chosen extension.
-
- I mainly wanted a small util to rename picture files in the format
- pic0000.jpg,pic0001.jpg,.....pic0033.jpg and be able to rename them back
- to the original name using amigados scripts. but I now use the program for
- various other tasks, keeping image names for web pages simple and also
- I have a pc running linux os and use ms-dos floppys to copy data files
- between the two. ms-dos as the long filename problem,
- It may be easier to archive the files - (lha keeps the long filenames), but
- is not always a good option for other reasons.
-
-
- I have included the source code with this program - I used Dice to
- compile it, but should compile using any compiler - use it as you wish.
-
- If you find this program or source code useful please e-mail me
- if not - sorry for wasting your time!
-
- Usage
- -----
- Arename <-ve> [directory] [name] [ext] <user ext>
-
- switches: -
- v = verbose - displays output to the screen
-
- e = this option allows you to select files by thier
- extension - the default is all files in the directory
- (including .info files)
-
-
- directory = containing files to rename (ie: work:images)
-
- name = new file name (ie: pics) this will be text before the
- numbers (ie: pics0000.img). use "" if you want just
- numbers (ie: 0000.img 0001.img 0002.img ....)
-
- ext = extension for new filename (ie: img) would produce
- img on the end of the renamed files (ie: frame0000.img)
-
- -*- Two important notes -*-
-
- 1) the script files created by this program (which will
- be created in the directory containing the files to
- be renamed) have the extension 'scp'. These files
- are ignored by the program.
-
- 2) This extension is used to make part of the script
- name, there are to scripts one to rename and one to
- undo. example if you choose img as the extension :-
-
- rename script : Arenimg.scp
- undo script : Aundimg.scp
-
-
- user ext = Will only rename files with this extension (use with -e)
- (ie: jpg - only jpeg files in the directory)
-
- example -:
- if you have a directory with different image types
- .iff .gif .ilbm .jpg and they all had .info files
- but you do not want to include the .info files in your
- renaming.
-
- :> Arename -ve work:mydirectory temp scp info
- :> execute Arenscp.scp
-
- this will change all .info files to have .scp
- as the extension.
- butterfly.jpg.info -> temp0000.scp
- cowboy.gif.info -> temp0001.scp
-
- :> Arename -v work:mydirectory frame img
- :> execute Arenimg.scp
-
- this will rename all the files in the directory
- ignoring the .scp files (which where mainly .info
- files) to.
- butterfly.jpg -> frame0000.img
- cowboy.gif -> frame0001.img
- -*- now do what you want with the image files -*-
-
- :> execute Aundscp.scp
- :> execute Aundimg.scp
-
- this will restore all files back to their original names
- if you want to.
-
- Examples
- --------
- example: Arename -v Work:pics holiday jpg
- this will rename all files in the chosen directory to:
-
- holiday0000.jpg,holiday0001.jpg,...holiday0023.jpg
-
- example: Arename -v Work:pics "" img
- this will rename all files in the chosen directory to:
-
- 0000.img,0001.img,0002.img,0003.img,...0023.img
-
- example: Arename -v Work:pics caves img jpg
- this will rename all files in the chosendirectory with the
- extension jpg to:
-
- caves0000.img,...caves0023.img
-
- -*- Mark Weller -*-
-
-
- ============================= Archive contents =============================
-
- Original Packed Ratio Date Time Name
- -------- ------- ----- --------- -------- -------------
- 12128 7035 41.9% 14-Jun-00 14:23:44 +Arename
- 9517 2382 74.9% 14-Jun-00 14:23:32 +Arename.c
- 4530 1629 64.0% 14-Jun-00 19:24:02 +Arename.readme
- -------- ------- ----- --------- --------
- 26175 11046 57.7% 15-Jun-100 06:56:40 3 files
-